SIS

All SIS desktop applications and the SIS Control can use translated resources to display language-specific text throughout. Other SIS products that have no user interface, eg GeognoSIS and SISpy, also use the translated resources, eg to get user-friendly property names.

The translated resources are automatically loaded by SIS from a Dynamic Link Library (DLL). This document describes how to create a SIS resource DLL.

Creating

Microsoft Visual Studio version requirements

Resource DLLs for this version of SIS can only be created using Microsoft Visual Studio 2017

Create a new Microsoft Visual Studio 2017 project

  • Start Microsoft Visual Studio 2017 and select the File/New/Project… command
  • Choose MFC from the Visual C++ Projects entry in the tree
  • Select MFC DLL icon from the list of templates, and choose a name and location for the project
  • Click the OK button to proceed to the configuration dialog
  • Click on the DLL type option, and choose MFC extension DLL from the types offered
  • Click the OK button to create the new project

Insert the SIS files into the project

  • Remove the default resources from the project by selecting the files project-name.rc and project-name.rc2 in the Solution Explorer tab and pressing the Delete key
  • Copy all of the SIS resource files into your project directory structure:

    Filename Description
    Resources.rc & .h Main SIS resource file
    Dialogs.rc & .h Dialogs, wizard page and Backstage page layouts
    res\Api.txt GeognoSIS HTTP API resource names and parameter descriptions
    res\Classes.txt Class names and descriptions
    res\Commands.txt Command names and descriptions
    res\DialogCues.rc2 Dialog control “cues” (background prompt text)
    res\DialogTips.rc2 Dialog control tooltips
    res\Expressions.txt Expression and expression parameter descriptions
    res\GisLink.txt GisLink API method and method parameter descriptions
    res\Operations.txt Operation and operation parameter descriptions
    res\Properties.txt Property names and descriptions
    res\RibbonBar.json Ribbon bar layout
    res\WizardPageHeaderTexts.rc2 Wizard page title strings
    res\Strings\*.txt All other strings (multiple files)
    build.h Version number header
    ResVersion.h Resource DLL version information
  • Add the Resources.rc and Dialogs.rc files to the project using the Project/Add Existing Item… command

Settings

  • Right-click on the the Solution in the Solution Explorer tab, and run the Properties command
  • Change the Configuration to Release, and the Platform to All Platforms, ie both 32-bit (called ‘Win32’ or ‘x86’) and 64-bit (called ‘x64’)
  • Select General from the Configurarion Properties tree, and change the Windows SDK Version to 8.1
  • Click OK to save the change

Building

Build compatibility

The Release build option must be chosen in order to be compatible with the released versions of the SIS applications and the SIS Control etc

  • Select the Build/Build <project name> command to compile and build the DLL

Using

  • Copy the built DLL to main directory of the SIS application or SIS Control

    The built DLL file can be found in the Release, or x64\Release for 64-bit builds, sub-directory of the Visual C++ project

Translated resource DLLs are loaded by both the SIS desktop applications and SIS Control from their own directory. The translated resource DLL must be called Cadcorp.SIS.Resources.???.DLL, where ??? is replaced by the three-letter abbreviation of the country code, eg JPN in Japan, FRA in France, etc. These three-letter abbreviations are based largely on ISO 3166-1 alpha-3.

SIS uses the default system locale to choose the translated file to load. This choice can be overridden in the SIS desktop and in GeognoSIS by using the --country:??? command-line parameter, where ??? is replaced by the three-letter abbreviation of the country code, as above.

Translating

Editing tools

Most translation can be carried out using any standard text editor that is character-encoding-aware. The exception to this is .rc file editing, which should be done using Microsoft Visual Studio 2017.

SIS resource file

File: Resource.rc

The majority of the translatable resources are in files loaded by this file, as described below. However, this file does contain a small String Table that can be translated.

Care must be taken to maintain the \n characters used to separate the document property parts of the IDR_xxx strings.

Dialogs

File: Dialogs.rc

All dialogs and wizard pages can be translated.

All static text may be translated, and any controls resized. Controls must not be removed, must not have their visibility toggled, and must not have their symbolic values changed, or SIS may crash.

The font of any dialog or wizard page may be changed, provided that the chosen font supports the local language.

GeognoSIS HTTP API

File: res\Api.txt

The GeognoSIS HTTP API descriptions can be translated.

Care must be taken to preserve the ‘|’-separated format, eg:

GetSchemas|Get Item Schemas

and to keep the ‘.’-separated format of the expression parameters, eg:

GetSchemas.f|Filter Expression

Classes

File: res\Classes.txt

The class names and descriptions can be translated.

Care must be taken to preserve the ‘¦’-separated format, eg:

ALabelTheme¦Labels¦Annotates themed Items by drawing a text label

Commands

File: res\Commands.txt

The command names and descriptions can be translated.

Some commands strings use a \t character to separate the description from the keyboard accelerator. The \t character must be in the translated strings, and the keyboard accelerator must not be changed.

Care must be taken to preserve the ‘¦’-separated format, eg:

AComArrangeAlign¦Align¦Aligns the selected Items

Dialog control cues

File: res\DialogCues.rc2

The dialog control cues can be translated.

The cue strings use octal notation for special characters which would otherwise interfere with the file format. In particular the following are used regularly:

Octal ASCII Character
\012 10 Line feed
\015 13 Carriage return
\042 34 ” (double quote)

Dialog control tooltips

File: res\DialogTips.rc2

The dialog control tooltips can be translated.

The special character rules for Dialog cues also apply to Dialog tooltips.

Expressions

File: res\Expressions.txt

The expression descriptions can be translated.

Care must be taken to preserve the ‘::’-separated format, eg:

And::Logical And operator, eg '_bSimple& And _bClosed&'

and to keep the ‘.’-separated format of the expression parameters, eg:

And.lhs::The expression on the left-hand side of the operator

File: res\GisLink.txt

The GisLink API descriptions can be translated.

Care must be taken to preserve the ‘|’-separated format, eg:

CopyListItems|Copies the Items in a Named List to the default overlay

and to keep the ‘.’-separated format of the expression parameters, eg:

CopyListItems.list|The Named List whose Items are to be copied

Operations

File: res\Operations.txt

The operation descriptions can be translated.

Care must be taken to preserve the ‘|’-separated format, eg:

Item.Buffer|Buffer|Creates a buffer around an Item

and to keep the ‘.’-separated format of the operations names and parameter names, eg:

Item.Buffer._radius@|Radius|The buffer radius, as a simple value, or as an expression, eg '12.34' or 'Max(123.4,Sqrt(_area#))'

Properties

File: res\Properties.txt

The property descriptions can be translated.

Care must be taken to preserve the ‘|’-separated format, eg:

_area#|Area|The area covered by the item, in square metres

and to keep the ‘. ‘-separated format of the non-item properties, eg:

Dts._bInTransaction&|In transaction|Is the dataset in a transaction?

Ribbon bar

File: res\RibbonBar.json

The Ribbon bar layout can be translated.

Care must be taken to preserve the JSON format.

Name and Label strings may be translated. The file contains as few of these as possible, using strings from Commands wherever practical.

Design Guidelines

The layout and order of Ribbon tabs can be changed, but should at all times bear in mind the restrictions in the Microsoft Office Fluent UI Design Guidelines.

Wizard page titles

File: res\WizardPageHeaderTexts.rc2

The wizard page title strings can be translated.

The special character rules for Dialog cues also apply to Dialog tooltips.

Strings

Files: res\Strings\*.txt

All other strings, in the files res\Strings\*.txt, can be translated, with the translated string added to the end of each line after the ¦ character.

Care must be taken to preserve the ‘¦’-separated format, eg:

1/2 Standard Deviation¦

Files and file categories

The strings have been split into multiple files for convenience of editing, ie to allow multiple files to be edited at once, and to reduce the workload where possible, eg to not translate res\Strings\Desktop.txt if the desktop applications do not require translation.

Within each file, strings are categorised to aid translation by providing context, eg all strings for length, area and angle units of measurement are in the [[[ Units ]]] category in the file res\Strings\Core.txt.

Special characters

Some characters in strings have special meaning, and must not be changed. These are .NET/Python-like zero-based positional placeholders, eg {0}, {1}, etc, and the \n separator. The order of the positional placeholders can be changed for local language reasons, eg:

The second ({1}) parameter can be moved before the first ({0}) parameter

Any trailing spaces must escaped using \, ie a \ character followed by a  (space) character.

Additional considerations

Task dialog strings

Some strings used in task dialogs, ie popup message boxes, have a special format that is decoded by SIS in order to populate different parts of the message.

  • The first part of the text, up to the first \n character is the main message
  • Additional information can be included between the first \n character up to a | or \t character, or the end of the string
  • Even more detailed information can be included after the | character up to a \t character, or the end of the string. The detailed information is not shown to the user by default, but a Show Details button will be displayed that, when clicked, reveals the information
  • Any string after a \t character will appear in the footer of the task dialog. The icon shown in the footer can be specified by using: (i) or (I) for the information icon; (!) for the warning icon; or (x) or (X) for the error icon
  • Footer strings can also include URLs, via a simplified HTML anchor element, eg <A HREF='http://www.cadcorp.com'>cadcorp.com</A>. NB the URL must be within single-quote (') characters for this feature to work

eg:

The current overlay type cannot store Blocks\t(i):You have to use a different overlay type (eg an Internal Dataset or a BDS file)¦

Cannot rename the file\nA file with the name you specified already exists.\t(i):%.256s¦

This file already exists\nReplace existing file?\t(i):%.256s¦

res\Strings\*.txt

The res\Strings\*.txt contains file type and extension strings, in the [[[ Files ]]] category. The \n character in these strings separates the long file type description that appears, for example, in a dropdown-list in the File/Open dialog, from the extension pattern, which is used, for example, to filter the files listed.

The \n character must not be removed from these strings, and it is recommended that the file extension patterns are not edited.

URLs

URLs containing // must have either both or just the second / escaped with a backslash, ie http:\/\/... or http:/\/... to avoid the // being considered a comment at the end of the line.

Changes since SIS 8.0

Dialogs

Added

IDD_AAdvancedBrushPage
IDD_AAdvancedPenPage
IDD_ABackstageDialogInfo
IDD_ABackstageDialogNew
IDD_ABackstageDialogSaveAs
IDD_ABackstageDialogStart
IDD_ABackstagePageExportToFile
IDD_ABackstagePageExportToServer
IDD_ABackstagePageExportToTiles
IDD_ABackstagePageOpenBrowse
IDD_ABackstagePageOpenRecent
IDD_ABackstagePagePrintTemplate
IDD_ABackstagePagePrintTemplateRecall
IDD_ABackstagePagePrintTemplateStore
IDD_ABackstagePageProjectBrowse
IDD_ABackstagePageProjectClose
IDD_ABackstagePageProjectRecent
IDD_ABackstagePagePublishToFile
IDD_ABackstagePagePublishToPDF
IDD_ABackstagePageUtilitiesLicensing
IDD_ABackstagePageUtilitiesOSGB
IDD_AControlBarEmpty
IDD_AControlBarGPS
IDD_AControlBarLibraries
IDD_AControlBarProperties
IDD_AControlBarSQL
IDD_AControlBarTree
IDD_ADateTimePopupDialog
IDD_ADeveloperPageLog
IDD_ADeveloperPagePython
IDD_AEditShapeDialog
IDD_AExportVideoDialog
IDD_AGradientPage
IDD_AGridPageGIStar
IDD_AGridPageHotSpot
IDD_AImportShapeDialog
IDD_AIsochronesDialog
IDD_AJSONDialog
IDD_AMapAlgebraDialog
IDD_AMarkdownDialog
IDD_AOverlayPageStyleCompositing
IDD_AOverlayPageStylePointCloud
IDD_AOverlayPageStyleTransparency
IDD_AOverlayPageTemporal
IDD_AOverlayPopupDialog
IDD_AOverlayWizardPageOSVML
IDD_AOverlayWizardPageProcessOperations
IDD_AOverlayWizardPageProcessSource
IDD_AOverlayWizardPageQuerySQL
IDD_AOverlayWizardPageTable
IDD_AOverlayWizardPageTileDataset
IDD_APrintPageTable
IDD_ASaverTdbViewer
IDD_ASpatialFormulaPageConfig
IDD_ASpatialFormulaPageType
IDD_ATemporalPageDate
IDD_ATemporalPageSlider
IDD_AThemePageBivariate
IDD_AThemePageFormula

Modified

IDD_AAboutDialog
IDD_AAddInManagerDialog
IDD_AApplicationKeyDialog
IDD_AComBuffer
IDD_AEditBrushDialog
IDD_AEditPenDialog
IDD_AFNtfDialog
IDD_AFormulaDialog
IDD_AFtableViewer
IDD_AGpsWizardPageReplay
IDD_AGridPageCreate
IDD_AGridPageKDE (renamed from IDD_AGridPageHotSpot)
IDD_AGridPageResult
IDD_AGridPageScatter
IDD_AIsoRouteDialog
IDD_ALegendDialog
IDD_ALicenceErrorDialog
IDD_ANolTreeDialog
IDD_AOverlayPageDataset
IDD_AOverlayPageGeneral
IDD_AOverlayPageStyle
IDD_AOverlayPageTheme
IDD_AOverlayPickerDialog
IDD_AOverlayWizardPageBrowseCreate
IDD_AOverlayWizardPageBrowseFile
IDD_AOverlayWizardPageBrowseMulti
IDD_AOverlayWizardPageBrowseSingle
IDD_AOverlayWizardPageCreate
IDD_AOverlayWizardPageCursor
IDD_AOverlayWizardPageDbo
IDD_AOverlayWizardPageIndex
IDD_AOverlayWizardPageNew
IDD_AOverlayWizardPageOgcCsw
IDD_AOverlayWizardPageOgcCswResults
IDD_AOverlayWizardPageOgcWcs
IDD_AOverlayWizardPageOgcWfs
IDD_AOverlayWizardPageOgcWfsConfig
IDD_AOverlayWizardPageOgcWms
IDD_AOverlayWizardPageOgcWmts
IDD_AOverlayWizardPageOracleSpatial
IDD_AOverlayWizardPageOsDnfAddress
IDD_AOverlayWizardPageOsDnfImagery
IDD_AOverlayWizardPageOsDnfIndex
IDD_AOverlayWizardPageOsDnfITN
IDD_AOverlayWizardPageOSMMGSP
IDD_AOverlayWizardPageOSMMHN
IDD_AOverlayWizardPagePostGis
IDD_AOverlayWizardPageRasterIndex
IDD_AOverlayWizardPageShibbolethFederation
IDD_AOverlayWizardPageSQLServer
IDD_AOverlayWizardPageURI
IDD_APrintPageKeyMap
IDD_APrintPageNorthPoint
IDD_APrintPagePrint
IDD_APrintPageScaleBar
IDD_AQueryWizardPageResults
IDD_ARouteDialog
IDD_ASaverBdbViewer
IDD_ASaverPdfPropertyPageOutput
IDD_ASaverPdfPropertyPageSecurity
IDD_ASelectItemDialog
IDD_AThemePageGraduatedStyle
IDD_AThemePageLabelStyle
IDD_AThemePageNew
IDD_AThemePagePieStyle
IDD_AThemePageProperty
IDD_AThemePagePropertyList
IDD_AWizardPageDatabaseBrowse
IDD_AWizardPageDatabaseBrowseCSV
IDD_AWizardPageDatabaseConfigCSVColumns
IDD_AWizardPageDatabaseConfigCSVDelimitedFile
IDD_AWizardPageDatabaseConfigCSVFile
IDD_AWizardPageDatabaseOracle
IDD_AWizardPageDatabasePostGreSQL
IDD_AWizardPageDatabaseSQLServer
IDD_AWizardPageDatabaseType
IDD_AWizardPageDatabaseTypeOsDnf
IDD_AWizardPageDatabaseTypeOSOpen
IDD_AWizardPageDatabaseTypeOSVectorMap

Deleted

IDD_AFileNewWizardPageBrowse
IDD_AFileNewWizardPageNew
IDD_AFileNewWizardPageSwdTemplate
IDD_AOverlayWizardPageDbi
IDD_AOverlayWizardPageDbo
IDD_AWizardPageDatabaseBrowseCreate

Assets

The SIS resource file pack can be downloaded from here